# Copyright (c) 2012 The Chromium Authors. All rights reserved.
# Copyright (c) 2012 The cwkshell Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

{
	'variables': {
		 'chromium_code': 1,
		  'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/cuc',
		   'chrome_grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/chrome',
		   'webkit_src_dir': '../third_party/WebKit',
		   'cuc_third_part_dir':'src/third_party',	
 	 },
	 'includes': [
		'../build/win_precompile.gypi',
		'cwkshell_resource.gypi',
		'src/third_party/inih.gypi',
		
	],
	  'conditions': [
	    	['component =="shared_library"', {
	    		 'includes': [			
						
			],
	    	}],
	     ],#conditions
	
 	 'target_defaults': {
	    'defines': ['CWKSHELL_IMPLEMENTATION',
	    		  #'CWKSHELL_MAINPAGE_MODE',
	    		  #'CWKSHELL_SKIN_BLACK',		
	    		  #'CWKSHELL_SKIN_BLUE',		
	    		  'CWKSHELL_SKIN_GRAY',		
	    		],
	   
  	},
	#projects:
  	 'targets': [
		 {
	      'target_name': 'cwkshell_view',
	      'type': 'static_library',
	      'dependencies': [
	        '../base/base.gyp:base',
	        '../base/base.gyp:base_i18n',
	        '../ui/base/strings/ui_strings.gyp:ui_strings',
	        '../build/temp_gyp/googleurl.gyp:googleurl',
	        '../chrome/chrome_resources.gyp:packed_resources',
	      
	        '../content/content.gyp:content',
	        '../skia/skia.gyp:skia',
	        '../third_party/icu/icu.gyp:icui18n',
	        '../third_party/icu/icu.gyp:icuuc',
	        '../ui/ui.gyp:ui',
	        '../ui/ui.gyp:ui_resources',	     
	        '../ui/views/views.gyp:views',
	    
	      ],
	       'product_name':'cwkshell_view',
	      'include_dirs': [
	        '../ui/',
	             '../third_party/wtl/include',
	             '<(grit_out_dir)',
	      ],
	       'direct_dependent_settings': {
          		  'include_dirs':[
          		  '../ui/',

	             '../third_party/wtl/include',
	             ],
	             
       	       },
	      'sources': [	 
   
	        'src/cwkshell/view/shell_window.cc',
	        'src/cwkshell/view/shell_window.h',	 
	        
	        'src/cwkshell/view/shell_unload_controller.cc',	 
	        'src/cwkshell/view/shell_unload_controller.h',	

		'src/cwkshell/view/shell_browser_window.cc',
       		'src/cwkshell/view/shell_browser_window.h',
       		'src/cwkshell/view/shell_browser_container.cc',
       		'src/cwkshell/view/shell_browser_container.h',	
       		'src/cwkshell/view/shell_browser_container_non_client_view.cc',	
       		'src/cwkshell/view/shell_browser_container_non_client_view.h',
       		'src/cwkshell/view/shell_browser_window_non_client_view.cc',	
       		'src/cwkshell/view/shell_browser_window_non_client_view.h',	
       		'src/cwkshell/view/shell_browser_dialog_non_client_view.cc',	
       		'src/cwkshell/view/shell_browser_dialog_non_client_view.h',	
		'src/cwkshell/view/app_modal_dialogs/app_modal_dialog.cc', 
		'src/cwkshell/view/app_modal_dialogs/app_modal_dialog.h', 
		'src/cwkshell/view/app_modal_dialogs/app_modal_dialog_queue.cc', 
		'src/cwkshell/view/app_modal_dialogs/app_modal_dialog_queue.h', 
		'src/cwkshell/view/app_modal_dialogs/javascript_app_modal_dialog.cc', 
		'src/cwkshell/view/app_modal_dialogs/javascript_app_modal_dialog.h', 
		'src/cwkshell/view/app_modal_dialogs/javascript_dialog_manager.cc', 
		'src/cwkshell/view/app_modal_dialogs/javascript_dialog_manager.h', 
		'src/cwkshell/view/app_modal_dialogs/native_app_modal_dialog.h', 
		'src/cwkshell/view/app_modal_dialogs/javascript_app_modal_dialog_views.cc',
		'src/cwkshell/view/app_modal_dialogs/javascript_app_modal_dialog_views.h',
		'src/cwkshell/view/app_modal_dialogs/javascript_app_modal_dialog_non_client_view.cc',
		'src/cwkshell/view/app_modal_dialogs/javascript_app_modal_dialog_non_client_view.h',
		'src/cwkshell/view/shell_browser_dialog.cc',
		'src/cwkshell/view/shell_browser_dialog.h',
	        'src/cwkshell/view/shell.rc',	 

	      ],
	      

			
	    },  # target_name: view
	  
	    {
	      'target_name': 'cwkshell_common',
	      'type': 'static_library',
	      'dependencies': [
			  '<(DEPTH)/base/base.gyp:base',
		        '<(DEPTH)/base/base.gyp:base_i18n',
		        '<(DEPTH)/base/base.gyp:base_static',
		        '<(DEPTH)/build/temp_gyp/googleurl.gyp:googleurl',
		      
		        '<(DEPTH)/content/content.gyp:content_common',
		        '<(DEPTH)/ipc/ipc.gyp:ipc',
		        '<(DEPTH)/net/net.gyp:net',
		        '<(DEPTH)/printing/printing.gyp:printing',
		        '<(DEPTH)/skia/skia.gyp:skia',
		        '<(DEPTH)/third_party/adobe/flash/flash_player.gyp:flapper_version_h',
		        '<(DEPTH)/third_party/bzip2/bzip2.gyp:bzip2',
		        '<(DEPTH)/third_party/icu/icu.gyp:icui18n',
		        '<(DEPTH)/third_party/icu/icu.gyp:icuuc',
		        '<(DEPTH)/third_party/libxml/libxml.gyp:libxml',
		        '<(DEPTH)/third_party/sqlite/sqlite.gyp:sqlite',
		        '<(DEPTH)/third_party/zlib/zlib.gyp:zlib',
		        '<(DEPTH)/ui/ui.gyp:ui_resources',
		        '<(DEPTH)/webkit/support/webkit_support.gyp:glue',
			],
	     
	      'include_dirs': [
	      	'../',
	      	'<(grit_out_dir)',
	      	'<(chrome_grit_out_dir)',
	      ],
	      'sources': [
	     
	          'src/cwkshell/common/cwkshell_switches.cc',
	         'src/cwkshell/common/cwkshell_switches.h',
	          'src/cwkshell/common/url_constants.cc',
	         'src/cwkshell/common/url_constants.h',
	         'src/cwkshell/common/jstemplate_builder.cc',
	         'src/cwkshell/common/jstemplate_builder.h',
	  
	      ],
	    },  # target_name: cwkshell_common
	     {
	      'target_name': 'cwkshell_browser',
	      'type': 'static_library',
	      'dependencies': [
	          '../content/content.gyp:content_app',
        '../content/content.gyp:content_browser',
        '../content/content.gyp:content_common',
        '../content/content.gyp:content_gpu',
        '../content/content.gyp:content_plugin',
        '../content/content.gyp:content_ppapi_plugin',
        '../content/content.gyp:content_renderer',
        '../content/content.gyp:content_shell_resources',
        '../content/content.gyp:content_utility',
        '../content/content.gyp:content_worker',
        '../content/content.gyp:test_support_content',
        '../content/content_resources.gyp:content_resources',
        '../base/base.gyp:base',
        '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
        '../build/temp_gyp/googleurl.gyp:googleurl',
	           '../ipc/ipc.gyp:ipc',
	        '../media/media.gyp:media',
	        '../net/net.gyp:net',
	        '../net/net.gyp:net_resources',
	        '../skia/skia.gyp:skia',
	    
	       '../ui/gl/gl.gyp:gl',
        '../ui/ui.gyp:ui',
        '../v8/tools/gyp/v8.gyp:v8',
	         '../webkit/support/webkit_support.gyp:webkit_resources',
        '../webkit/support/webkit_support.gyp:webkit_support',
        '<(webkit_src_dir)/Source/WebKit/chromium/WebKit.gyp:webkit',
        '<(webkit_src_dir)/Source/WebKit/chromium/WebKit.gyp:webkit_test_support',
        '<(webkit_src_dir)/Tools/DumpRenderTree/DumpRenderTree.gyp/DumpRenderTree.gyp:TestRunner',
	        '../ui/web_dialogs/web_dialogs.gyp:web_dialogs',

	        'tp_inih',
	      ],
	      'product_name':'cwkshell_browser',
	      'include_dirs': [
	        '../',
		   '<(grit_out_dir)',
	      ],
	      'sources': [
	     	
			    'src/cwkshell/browser/disposition_utils.cc', 
		'src/cwkshell/browser/disposition_utils.h', 
		'src/cwkshell/browser/file_select_helper.cc', 
		'src/cwkshell/browser/file_select_helper.h', 
		'src/cwkshell/browser/platform_util.cc', 
		'src/cwkshell/browser/platform_util.h', 
		'src/cwkshell/browser/shell_browser.cc', 
		'src/cwkshell/browser/shell_browser.h', 
		'src/cwkshell/browser/shell_browser_context.cc', 
		'src/cwkshell/browser/shell_browser_context.h', 
		'src/cwkshell/browser/shell_browser_main.cc', 
		'src/cwkshell/browser/shell_browser_main.h', 
		'src/cwkshell/browser/shell_browser_main_parts.cc', 
		'src/cwkshell/browser/shell_browser_main_parts.h', 
		'src/cwkshell/browser/shell_content_browser_client.cc', 
		'src/cwkshell/browser/shell_content_browser_client.h', 
		'src/cwkshell/browser/shell_content_renderer_client.cc', 
		'src/cwkshell/browser/shell_content_renderer_client.h', 
		'src/cwkshell/browser/shell_devtools_delegate.cc', 
		'src/cwkshell/browser/shell_devtools_delegate.h', 
		'src/cwkshell/browser/shell_devtools_frontend.cc', 
		'src/cwkshell/browser/shell_devtools_frontend.h', 
		'src/cwkshell/browser/shell_download_manager_delegate.cc', 
		'src/cwkshell/browser/shell_download_manager_delegate.h', 
		'src/cwkshell/browser/shell_messages.cc', 
		'src/cwkshell/browser/shell_messages.h', 
		'src/cwkshell/browser/shell_message_filter.cc', 
		'src/cwkshell/browser/shell_message_filter.h', 
		'src/cwkshell/browser/shell_network_delegate.cc', 
		'src/cwkshell/browser/shell_network_delegate.h', 
		'src/cwkshell/browser/shell_protocol_handler.cc', 
		'src/cwkshell/browser/shell_protocol_handler.h', 
		'src/cwkshell/browser/shell_quota_permission_context.cc', 
		'src/cwkshell/browser/shell_quota_permission_context.h', 
		'src/cwkshell/browser/shell_render_process_observer.cc', 
		'src/cwkshell/browser/shell_render_process_observer.h', 
		'src/cwkshell/browser/shell_resource_context.cc', 
		'src/cwkshell/browser/shell_resource_context.h', 
		'src/cwkshell/browser/shell_resource_dispatcher_host_delegate.cc', 
		'src/cwkshell/browser/shell_resource_dispatcher_host_delegate.h', 
		'src/cwkshell/browser/shell_test_configuration.cc', 
		'src/cwkshell/browser/shell_test_configuration.h', 
		'src/cwkshell/browser/shell_url_request_context_getter.cc', 
		'src/cwkshell/browser/shell_url_request_context_getter.h', 
		'src/cwkshell/browser/shell_web_contents_view_delegate.h', 
		'src/cwkshell/browser/shell_web_contents_view_delegate_creator.h', 
		'src/cwkshell/browser/shell_web_contents_view_delegate_win.cc', 


		'src/cwkshell/browser/diagnostics/sqlite_diagnostics.cc',
		'src/cwkshell/browser/diagnostics/sqlite_diagnostics.h',

		
		'src/cwkshell/browser/geolocation/shell_access_token_store.cc',
		'src/cwkshell/browser/geolocation/shell_access_token_store.h',
		
		'src/cwkshell/browser/ui/shell_select_file_policy.cc',
		'src/cwkshell/browser/ui/shell_select_file_policy.h',
		

		'src/cwkshell/browser/jsextension/cuc_object.cc',		
		'src/cwkshell/browser/jsextension/cuc_object.h',		
		


	      ],
	     
	    
	    },  # target_name: browser
	    {
	      'target_name': 'cwkshell_app',
	      'type': 'static_library',
	      'dependencies': [
	          '../sandbox/sandbox.gyp:sandbox',
	        '../base/base.gyp:base',
	        '../base/base.gyp:base_i18n',
	        '../content/content.gyp:content',
	        '../skia/skia.gyp:skia',
	        '../third_party/icu/icu.gyp:icui18n',
	        '../third_party/icu/icu.gyp:icuuc',
	        '../ui/ui.gyp:ui',
	        'cwkshell_browser',
	        'cwkshell_view',	     
	         'cwkshell_pak',
	          'cwkshell_common',
	          '../third_party/mesa/mesa.gyp:osmesa',
	      ],
	  
	      'include_dirs': [
	        '../',
	      ],
	     
	      'sources': [
	        '../content/app/startup_helper_win.cc',
	        'src/cwkshell/app/shell_main_delegate.cc',
	        'src/cwkshell/app/shell_main_delegate.h',
	        'src/cwkshell/app/shell_content_client.cc',
	        'src/cwkshell/app/shell_content_client.h',
	        'src/cwkshell/app/shell.h',
	        'src/cwkshell/app/shell.cc',
	        'src/cwkshell/app/shell_property.cc',
	        'src/cwkshell/app/shell_property.h',
	   
	      ],
	      
	    
	    },  # target_name: app
	   
	     {
	      'target_name': 'cwkshell',
	      'type': 'executable',
	      'dependencies': [
		       		'cwkshell_app',
		       		
			],
	     
	      'include_dirs': [
	        '../',
	      ],
	      'sources': [
	        'src/cwkshell/app/cwkshell.rc',
	        'src/cwkshell/shell_main.cc',
	  
	      ],
	      'conditions': [
	        ['OS=="win"', {
	          'link_settings': {
	            'libraries': [
	              '-limm32.lib',
	              '-loleacc.lib',
	            ]
	          },
	          'msvs_settings': {
	            'VCManifestTool': {
	              'AdditionalManifestFiles': 'src\\cwkshell\\cwkshell.exe.manifest',
	            },
	            'VCLinkerTool': {
	              'SubSystem': '2',  # Set /SUBSYSTEM:WINDOWS
	            },
	          },
	         
	        }],
	        
	        ['OS=="win"', {
	          'sources/': [
	            # This is needed because the aura rule strips it from the default
	            # sources list.
	            ['include', '^../content/app/startup_helper_win.cc'],
	          ],
	        }],
	      ],
	    },  # target_name: shell_exe

	    
	]
}